package com.cloud.rou.im.core.base;

import lombok.Data;

import java.io.Serializable;

/**
 * <p></p>
 *
 * @author GaoShuangWen
 * @since 2019-10-30 16:29
 */
@Data
public class ResultVO implements Serializable {

    private Boolean success;

    private Long msgId;

    public static ResultVO fail(Long msgId) {
        ResultVO resultVO = new ResultVO();
        resultVO.setSuccess(false);
        resultVO.setMsgId(msgId);
        return resultVO;
    }

    public static ResultVO success(Long msgId) {
        ResultVO resultVO = new ResultVO();
        resultVO.setSuccess(true);
        resultVO.setMsgId(msgId);
        return resultVO;
    }

}
